<!DOCTYPE html>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		<meta id="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" name="viewport">
		<meta name="apple-themes-web-app-capable" content="yes">
		<meta content="yes" name="apple-mobile-web-app-capable">
		<meta content="black" name="apple-mobile-web-app-status-bar-style">
		<meta content="telephone=no" name="format-detection">
		<meta content="email=no" name="format-detection">
		<meta name="format-detection" content="telephone=no">
		<title>往期揭晓</title>
		<link rel="stylesheet" href="${s.base}/mobile/css/weui.min.css">
		<link rel="stylesheet" href="${s.base}/mobile/css/main.css" type="text/css" media="all">
		<link rel="stylesheet" href="${s.base}/mobile/css/dropload.css" type="text/css" media="all">
	</head>

	<body>
 	<!--页面加载 开始-->
     <!--<div id="preloader">
     <div id="status">
      <p class="center-text"><span>拼命加载中···</span></p>
     </div>
    </div>-->
    <!--页面加载 结束-->    
		<header id="header">
			<div class="header_con">
				<a href="javascript:history.go(-1);"><span></span></a> 
                <div class="top_tit">往期揭晓</div>         
			</div>
		</header>
		<div id="content_div" >
            <div class="wq_list" id="showContent">
              <!--<ul>
              <h2>期号： 3328 <span>开奖时间：2016-08-29 13:00:00</span></h2>
              <li>
               <i style="background: url(images/tx01.jpg) no-repeat;background-size: 0.56rem 0.56rem;"></i>
               <p><span>获得者：</span> <em>潇洒哥</em> （本期参与10人次）</p>
               <p><span>幸运号： </span> <em>100894</em></p>
               <p><span>总   需：</span>  10000人次</p>
              </li>
              </ul>-->

             </div>
      </div>
		<div class="content">
			<div class="lists"></div>
		</div>
      <!--底部-->
      <!--底部结束-->
	<script type="text/javascript" src="${s.base}/mobile/js/zepto.min.js"></script>
    <script type="text/javascript" src="${s.base}/mobile/js/dropload.min.js"></script>
    <script>
        $(function(){
            var memberId = '${memberId}';
            var itemId = '${itemId}';
            // 每页展示5个
            var num = 5;
            var pageStart = 0,pageEnd = 0;
            // dropload
            $('#content_div').dropload({
                scrollArea : window,
                loadDownFn : function(me){
                    pageStart++;
                    $.post("/activity/jsonPastActList",{
                        limit : num,
                        page : pageStart,
                        orderType : 4,
                        itemId : itemId,
                        status : 2
                    },function(resultInfo){
                        if (resultInfo.code == 0){
                            var result = '';
                            if (resultInfo.data!=null && resultInfo.data.length > 0){
                                for(var i=0;i<resultInfo.data.length;i++){
                                    //console.log("测试:"+counter);
                                    var items=resultInfo.data[i];
                                    result += ' <ul onclick="window.location.href=\'/phone/itemBuyList/'+items.id+'?memberId='+memberId+'\'">'+
                                        '<h2>期号： '+items.periodsNum+' <span>开奖时间：'+items.updateTime+'</span></h2>'+
                                        '<li>'+
                                        '<i style="background: url('+items.imageOne+') no-repeat;background-size: 0.56rem 0.56rem;"></i>'+
                                        '<p><span>获得者：</span> <em>'+items.memberName+'</em> （本期参与'+items.winInNum+'人次）</p>'+
                                        '<p><span>幸运号： </span> <em>'+items.winningNum+'</em></p>'+
                                        '<p><span>总   需：</span>  '+items.totalNum+'人次</p>'+
                                        '</li>'+
                                        '</ul>';
                                }

                            }

                            $('#showContent').append(result);
                            // 每次数据加载完，必须重置
                            if(resultInfo.isLastPage||resultInfo.isLastPage=="true"){
                                me.lock();
                                // 无数据
                                me.noData();
                                $(".dropload-down").remove();
                            }else {
                                me.resetload();
                            }
                        }
                    },"json");
                }
            });
        });
    </script>
	<script type="text/javascript" src="${s.base}/mobile/js/common.js"></script>
	</body>

</html>